<!DOCTYPE html>
<html>
    <head>
        <title>推荐</title>
        <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
        <meta
            name="viewport"
            content="viewport-fit=cover,initial-scale=1.0,maximum-scale=1.0,minimum-scale=1.0,user-scalable=no,target-densitydpi = medium-dpi"
        />
        <meta name="format-detection" content="telephone=no" />
        <meta name="apple-touch-fullscreen" content="YES" />
        <meta name="apple-mobile-web-app-capable" content="yes" />
        <meta name="apple-mobile-web-app-status-bar-style" content="black" />
        <link href="../c_modules/css/base-min.css" rel="stylesheet" media="all" />
        <link rel="stylesheet" href="../c_modules/swiper/css/swiper.min.css" />
        <link href="../c_modules/jz/mescroll.min.css" rel="stylesheet" />
        <link rel="stylesheet" href="./css/home_newCommon6.css" />

        <!--推荐-->
        <link rel="stylesheet" href="./skin01/home_new_yh01.css" />

        <!--724-->
        <link rel="stylesheet" href="/zx2/skin01/zx_tuijian.css" />
        <link rel="stylesheet" href="/zx2/skin01/zx_kuaixun.css" />

        <link rel="stylesheet" href="./css/home_new_index_reform6.css" />
    </head>

    <body>
        <!--mescroll-->
        <div class="tuijian main" id="mescroll-tuijian">
            <!--今日关注-->
            <div class="home_new-list jrgz">
                <div class="tztui-list-title jr-title pad15">
                    <div class="btm-line">
                        <span class="title">今日关注</span>
                        <span class="title-font1"> 今日机会提醒 </span>
                        <span class="more"> <!--更多--><i class="right-arrow"></i> </span>
                    </div>
                </div>
                <div class="home_new-list-content jrgz-box">
                    <div class="swiper-container-jrgz">
                        <div class="swiper-wrapper">
                            <div class="swiper-slide" style="width: 2.864rem; margin-right: 0.11rem">
                                <div class="box-item">
                                    <div class="box-title">
                                        <!--<span class="title-left">01 <img src="./images/jrgz.png" alt="jrgz"></span>-->
                                        <span class="title-mid chunk-default">默认模块</span>
                                        <span class="title-right chunk-default">00:00</span>
                                    </div>
                                    <div class="box-content1">
                                        <div class="content-top">
                                            <div class="chunk-default">
                                                默认介绍内容 默认介绍内容 默认介绍内容 默认介绍内容
                                            </div>
                                        </div>
                                        <p class="content-bottom clear">
                                            <span class="left chunk-default">默认股票 --</span>
                                            <span class="right chunk-default">默认股票 --</span>
                                        </p>
                                    </div>
                                </div>
                            </div>
                            <div class="swiper-slide" style="width: 2.864rem; margin-right: 0.11rem">
                                <div class="box-item">
                                    <div class="box-title">
                                        <!--<span class="title-left">02 <img src="./images/jrgz.png" alt="jrgz"></span>-->
                                        <span class="title-mid chunk-default">默认模块</span>
                                        <span class="title-right chunk-default">00:00</span>
                                    </div>
                                    <div class="box-content1">
                                        <div class="content-top">
                                            <div class="chunk-default">
                                                默认介绍内容 默认介绍内容 默认介绍内容 默认介绍内容
                                            </div>
                                        </div>
                                        <p class="content-bottom clear">
                                            <span class="left chunk-default">默认股票 --</span>
                                            <span class="right chunk-default">默认股票 --</span>
                                        </p>
                                    </div>
                                </div>
                            </div>
                        </div>
                    </div>
                </div>
            </div>
            <!-- 推广图 -->
            <div class="extension-banner">
                <!--<img src="/common/img/banner_mall_LCZX.png" alt="">-->
            </div>
            <!--今日风口-->
            <div class="home_new-list jrfk">
                <div class="tztui-list-title jr-title pad15">
                    <div class="btm-line">
                        <span class="title">今日风口</span>
                        <span class="title-font1"> 实时大涨解读 </span>
                        <span class="more"> <!--更多--><i class="right-arrow"></i> </span>
                    </div>
                </div>
                <div class="home_new-list-content jrfk-box">
                    <div class="swiper-container-jrfk">
                        <div class="swiper-wrapper">
                            <div class="swiper-slide" style="width: 1.523rem; margin-right: 0.11rem">
                                <div class="box-item box-item1">
                                    <div class="box-title">
                                        <p class="title f6f8"><!--ST中南--></p>
                                        <p class="value f6f8"><!--+23.18%--></p>
                                    </div>
                                    <div class="box-content">
                                        <p class="content-top f6f8">
                                            <!--低价,此前连续6日跌停,主营影视文化和金属制造业务-->
                                        </p>
                                        <p class="content-bottom f6f8">
                                            <span class="left"><!--新晨科技--></span>
                                            <span class="right"><!--+10.12%--></span>
                                        </p>
                                    </div>
                                </div>
                            </div>
                            <div class="swiper-slide" style="width: 1.523rem; margin-right: 0.11rem">
                                <div class="box-item box-item2">
                                    <div class="box-title">
                                        <p class="title f6f8"><!--区块链--></p>
                                        <p class="value f6f8"><!--+48.78%--></p>
                                    </div>
                                    <div class="box-content">
                                        <p class="content-top f6f8">
                                            <!--低价,此前连续6日跌停,主营影视文化和金属制造业务-->
                                        </p>
                                        <p class="content-bottom f6f8">
                                            <span class="left"><!--新晨科技--></span>
                                            <span class="right"><!--+10.12%--></span>
                                        </p>
                                    </div>
                                </div>
                            </div>
                            <div class="swiper-slide" style="width: 1.523rem; margin-right: 0.11rem">
                                <div class="box-item box-item2">
                                    <div class="box-title">
                                        <p class="title f6f8"><!--ST中南--></p>
                                        <p class="value f6f8"><!--+23.18%--></p>
                                    </div>
                                    <div class="box-content">
                                        <p class="content-top f6f8">
                                            <!--低价,此前连续6日跌停,主营影视文化和金属制造业务-->
                                        </p>
                                        <p class="content-bottom f6f8">
                                            <span class="left"><!--新晨科技--></span>
                                            <span class="right"><!--+10.12%--></span>
                                        </p>
                                    </div>
                                </div>
                            </div>
                        </div>
                    </div>
                </div>
            </div>
            <!-- 要闻前三条 -->
            <div class="yaowen-list yaowen-list-three"></div>

            <!-- 投顾观点两条 -->
            <!--        <div class="tougu-group tggd"></div>-->
            <!-- 视频列表一条 -->
            <!--        <div class="video-list"></div>-->
            <!-- 要闻前三条之后的数据 -->
            <div class="yaowen-list yaowen-list-other"></div>
        </div>
        <script src="../c_modules/jz/mescroll.min.js" charset="utf-8"></script>
        <script src="../c_modules/jquery-1.7.1.min.js"></script>
        <script src="../c/TZT.js"></script>
        <script src="../c_modules/swiper/js/swiper.min.js"></script>
        <script type="text/javascript" src="js/md5.js"></script>
        <script src="js/crypto-js.js"></script>
        <script type="text/javascript" src="js/jsencrypt.js"></script>
        <script src="../common/js/commonFunction.js"></script>
        <script src="../common/js/sticky.min.js"></script>

        <script src="../common/tracking/index.js"></script>
        <script src="../common/tracking/tracking-plugin.js"></script>
        <script src="../common/tracking/tracking-config.js"></script>
        <script src="./js//setHeight.js"></script>
        <script>
            var oVal = {};
            var readId = [];
            oVal.ywPageNum = 1;
            oVal.loadYWFlag = true;
            oVal.infoOffset = '0'; //取接口返回的字段
            var pageSensors = new track.Tracker();
            pageSensors.registerPageModule('SY');
            // 页面浏览 page
            pageSensors.reportPageView('pageView');
            //获取46200配置文件信息
            getConfigInfo(function () {
                tuijianInit();
            });

            function tuijianInit() {
                getJRGZ(); //今日关注
                //getTGGD();//投顾两条
                //getSPKC();//视频课程一条
                //mescroll.endSuccess();
            }

            //今日关注
            function getJRGZ() {
                var oSendData = {
                    action: '50050' /*46118*/,
                    channel_num: '1', //渠道识别，备注：可以在配置文件里面改，要和华福约定，暂时先用1
                    menu_id: '20146',
                    nPage: 1,
                    maxcount: 10,
                    ReqLinkType: '2',
                };
                $.getData({
                    oSendData: oSendData,
                    isload: false,
                    fnSuccess: function (data) {
                        //console.log("今日关注：",data);
                        if (data && data.GRID0.length >= 1) {
                            $('.jrgz').show();
                            var oData = [];
                            for (var j = 0; j < data.GRID0.length; j++) {
                                oData.push(data.GRID0[j].split('|'));
                            }
                            var title = ['01', '02', '03'];
                            var itemHtml = '';
                            itemHtml +=
                                '<div class="swiper-container-jrgz">\n' + '\t\t\t\t\t\t<div class="swiper-wrapper">';
                            var _ln = '';
                            if (data.GRID0.length > 3) {
                                _ln = 3;
                            } else {
                                _ln = data.GRID0.length;
                            }
                            var itemLocation = ['今日关注位置一', '今日关注位置二', '今日关注位置三'];
                            var jrgz_code_arr = [];
                            for (var i = 0; i < _ln; i++) {
                                oData[i][data.DATE] = setDateTime(oData[i][data.DATE]).format('yyyy-MM-dd hh:mm:ss');
                                var timehtml = oData[i][data.DATE].split(' ')[1];
                                timehtml = timehtml.split(':')[0] + ':' + timehtml.split(':')[1];

                                var paiming = oData[i][data.HOT].trim();
                                if (Number(paiming) < 10) {
                                    paiming = '0' + paiming;
                                }

                                //处理股票
                                var gpData = oData[i][data.STOCKS],
                                    gphtml = '';
                                //gpData="首创股份,600008;飞乐音响,600651;飞乐音响1,600652";
                                if (gpData) {
                                    gpData = gpData.split(';'); //还不确定是不是以分号,逗号区分，先默认分号,逗号;类似：（勤上股份,002638;飞乐音响,600651）
                                    for (var k = 0; k < gpData.length; k++) {
                                        if (k < 2) {
                                            //默认只取前两支股票
                                            //存储股票代码信息
                                            jrgz_code_arr.push(gpData[k].split(',')[1]);

                                            gphtml +=
                                                '<span><i class="code" data-market="' +
                                                gpData[k].split(',')[2] +
                                                '" data-id="' +
                                                gpData[k].split(',')[1] +
                                                '">' +
                                                gpData[k].split(',')[0] +
                                                '</i><i class="range"> --</i></span>'; //关于涨幅等dom加载完后再获取
                                        } else {
                                            break;
                                        }
                                    }
                                }
                                itemHtml +=
                                    '<div class="swiper-slide" style="width: 2.864rem; margin-right: 0.11rem;">\n' +
                                    '\t\t\t\t\t\t\t<div class="box-item" data-index="' +
                                    i +
                                    '" data-location="' +
                                    itemLocation[i] +
                                    '" plate-id="' +
                                    Number(oData[i][data.PLATEID]).toFixed(0) +
                                    '" data-id="' +
                                    Number(oData[i][data.INFOCODE]).toFixed(0) +
                                    '">\n' +
                                    '\t\t\t\t\t\t\t\t<div class="box-title">\n' +
                                    '\t\t\t\t\t\t\t\t\t<span class="title-left">' +
                                    paiming +
                                    '<img src="./images/jrgz.png" alt="jrgz"></span>\n' +
                                    '\t\t\t\t\t\t\t\t\t<span class="title-mid">' +
                                    oData[i][data.FATTURED_TITLE] +
                                    '</span>\n' +
                                    '\t\t\t\t\t\t\t\t\t<span class="title-right">' +
                                    timehtml +
                                    '</span>\n' +
                                    '\t\t\t\t\t\t\t\t</div>\n' +
                                    '\t\t\t\t\t\t\t\t<div class="box-content1">\n' +
                                    '\t\t\t\t\t\t\t\t\t<p class="content-top">' +
                                    oData[i][data.TITLE] +
                                    '</p>\n' +
                                    '\t\t\t\t\t\t\t\t\t<p class="content-bottom clear">' +
                                    gphtml +
                                    '</p>\n' +
                                    '\t\t\t\t\t\t\t\t</div>\n' +
                                    '\t\t\t\t\t\t\t</div>\n' +
                                    '\t\t\t\t\t\t</div>';
                                timehtml = null;
                            }
                            itemHtml +=
                                '<div class="sfckgd-p"><div class="sfckgd">释放查看更多 <img src="./images/sf_right.png" alt=""></div></div>';

                            itemHtml += '</div></div>';
                            $('.jrgz .jrgz-box').html(itemHtml);
                            //$('.jrgz .swiper-wrapper').html(itemHtml);
                            //获取涨跌幅
                            getStock2(jrgz_code_arr);
                            //重置dom点击事件
                            JRGZEvent();
                            oVal.swiper_jrgz = new Swiper('.swiper-container-jrgz', {
                                slidesPerView: 'auto',
                                spaceBetween: 10,
                                slidesOffsetAfter: 5,
                                onTouchEnd: function (swiper, event) {
                                    //在最后一页继续拖动则释放跳转
                                    //console.log("跳转事件执行",swiper.translate,event);
                                    var _width = $('.jrgz-box .swiper-slide').width() * 2;
                                    if (swiper.translate + _width < -40) {
                                        //console.log("跳转")
                                        var oSend = { url: '/zx2/zx_chance.html' };
                                        T.fn.action10061(oSend);
                                        /*onJsOverrideUrlLoading("http://action:11004?type=jh");*/
                                    }
                                },
                            });
                        } else {
                            $('.jrgz').hide();
                        }
                        getJRFK(); //今日风口
                    },
                    oConfig: function (error) {
                        console.log('今日关注接口报错：', error);
                        $('.jrgz').hide();
                        getJRFK(); //今日风口
                    },
                });
            }
            function JRGZEvent() {
                //跳转机会模块
                $('.jrgz .more')
                    .off()
                    .on('click', function () {
                        //今日关注事件埋点
                        track.sensors.track('second_list_click', {
                            bottomtabbar_name: '探索',
                            toptabbar_name: '首页',
                            first_list_name: '今日关注',
                            second_list_type: '列表',
                            second_list_name: '今日关注',
                        });

                        // 首页栏位点击-今日关注-更多
                        pageSensors.reportClick('mainPageColumnClick', {
                            column_type: '今日关注',
                            column_name: '今日关注-更多',
                            column_no: '',
                        });

                        var oSend = { url: '/zx2/zx_chance.html?' };
                        T.fn.action10061(oSend);
                        /*onJsOverrideUrlLoading("http://action:11004?type=jh");*/
                    });
                $('.jrgz .box-item')
                    .off()
                    .on('click', function () {
                        //今日关注列表事件埋点
                        var location = $(this).attr('data-location');
                        var index = $(this).attr('data-index');
                        if (location) {
                            track.sensors.track('second_list_click', {
                                bottomtabbar_name: '探索',
                                toptabbar_name: '首页',
                                first_list_name: '今日关注',
                                second_list_type: '列表位置',
                                second_list_name: location,
                            });
                        }

                        // 首页栏位点击-栏目-更多
                        pageSensors.reportClick('mainPageColumnClick', {
                            column_type: '今日关注',
                            column_name: $(this).find('.content-top').text(),
                            column_no: index,
                        });

                        var sId = $(this).attr('plate-id');
                        var obj = {
                            url: '/hq/zt_xq.html?id=' + sId + '',
                        };
                        var oSend = { url: obj.url };
                        TZT.fn.action10061(oSend);
                    });
                //跳转个股行情页
                $('.jrgz .content-bottom span')
                    .off()
                    .on('click', function (event) {
                        T.stopBubble();
                        var stockcode = $(this).find('.code').attr('data-id');
                        var stocktype = $(this).find('.code').attr('data-market');
                        onJsOverrideUrlLoading(
                            'http://action:12051/?stockcode=' + stockcode + '&&stocktype=' + stocktype
                        );
                    });
            }

            //今日风口
            function getJRFK() {
                var oSendData = {
                    action: '50052',
                    channel_num: '1', //渠道识别，备注：可以在配置文件里面改，要和华福约定，暂时先用1
                    menu_id: '001',
                    ReqLinkType: '2',
                    nPage: 1,
                    maxcount: 3,
                };
                $.getData({
                    oSendData: oSendData,
                    isload: false,
                    fnSuccess: function (data) {
                        //console.log("今日风口-大涨解读：",data);
                        if (data && data.GRID0.length >= 1) {
                            $('.jrfk').show();
                            var oData = [],
                                oData1 = [];
                            for (var j = 0; j < data.GRID0.length; j++) {
                                oData.push(data.GRID0[j].split('|'));
                            }
                            jrfk_data = data;
                            jrfk_oData = oData;
                            //循环grid1
                            /*for(var k=0;k<oData.length;k++){
                            if(data.PLATE_ID>0){
                                getZTXQ(oData[k][data.PLATE_ID],oData.length);
                            }
                        }*/

                            //console.log("主题涨跌幅数据：",zdf_arr)
                            //板块描述
                            var _bkms = '',
                                bkmsIndex = data.PLATE_DESC;
                            //主题对应股票
                            var gpname = '',
                                gpcode = '',
                                gphtml = '';
                            var itemHtml = '';

                            itemHtml +=
                                '<div class="swiper-container-jrfk">\n' + '\t\t\t\t\t\t<div class="swiper-wrapper">';
                            var itemLocation = ['今日风口位置一', '今日风口位置二', '今日风口位置三'];
                            for (var i = 0; i < 3; i++) {
                                gphtml =
                                    '<span class="left code" data-id="' +
                                    gpcode +
                                    '">' +
                                    gpname +
                                    '</span><span class="right range"> --</span>'; //关于涨幅等dom加载完后再获取

                                var _gpZDF = oData[i][data.CORE_PCP],
                                    _gpZDFclass = '';
                                if (_gpZDF > 0) {
                                    _gpZDF = '+' + parseFloat(_gpZDF).toFixed(2) + '%';
                                    _gpZDFclass = 'zf';
                                } else {
                                    _gpZDF = parseFloat(_gpZDF).toFixed(2) + '%';
                                    _gpZDFclass = 'df';
                                }

                                itemHtml +=
                                    '<div class="swiper-slide" style="width: 1.523rem; margin-right: 0.11rem;">\n' +
                                    '\t\t\t\t\t\t\t<div class="box-item box-item1" data-location="' +
                                    itemLocation[i] +
                                    '">\n' +
                                    '\t\t\t\t\t\t\t\t<div class="box-title">\n' +
                                    '\t\t\t\t\t\t\t\t\t<p class="title" data-id="' +
                                    oData[i][data.PLATE_ID] +
                                    '">' +
                                    oData[i][data.PLATE_NAME] +
                                    '</p>\n' +
                                    '\t\t\t\t\t\t\t\t\t<p class="value ' +
                                    _gpZDFclass +
                                    '">' +
                                    _gpZDF +
                                    '</p>\n' +
                                    '\t\t\t\t\t\t\t\t</div >\n' +
                                    '\t\t\t\t\t\t\t\t<div class="box-content">\n' +
                                    '\t\t\t\t\t\t\t\t\t<p class="content-top">' +
                                    _bkms +
                                    '</p>\n' +
                                    '\t\t\t\t\t\t\t\t\t<p class="content-bottom">' +
                                    gphtml +
                                    '</p>\n' +
                                    '\t\t\t\t\t\t\t\t</div >\n' +
                                    '\t\t\t\t\t\t\t</div>\n' +
                                    '\t\t\t\t\t\t</div>';
                            }
                            itemHtml +=
                                '<div class="sfckgd-p"><div class="sfckgd">释放查看更多 <img src="./images/sf_right.png" alt=""></div></div>';

                            itemHtml += '</div></div>';
                            $('.jrfk .jrfk-box').html(itemHtml);

                            //$('.jrfk .swiper-wrapper').html(itemHtml);
                            /*$(".jrfk .content-bottom").each(function () {
                            getStock($(this).find(".code").attr("data-id"),$(this).find(".range"));
                        });*/

                            $('.jrfk .box-item .box-title').each(function () {
                                var _id = $(this).find('.title').attr('data-id');
                                var _dom1 = $(this).parent().find('.content-top');
                                var _dom2 = $(this).parent().find('.range');
                                getZTXQ(_id, _dom1, _dom2);
                            });

                            JRFKEvent();
                            var swiper_jrfk = new Swiper('.swiper-container-jrfk', {
                                slidesPerView: 'auto',
                                spaceBetween: 10,
                                slidesOffsetAfter: 5,
                                onTouchEnd: function (swiper, event) {
                                    //在最后一页继续拖动则释放跳转
                                    var _width = $('.jrfk .swiper-slide').width();
                                    //console.log("跳转事件执行",swiper.translate,_width);
                                    if (swiper.translate + _width < -50) {
                                        //console.log("跳转")
                                        var oSend = { url: '/hq/jrfk.html' };
                                        T.fn.action10061(oSend);
                                    }
                                },
                            });
                        } else {
                            $('.jrfk').hide();
                        }
                        getYaoWenInfo(); //要闻三条
                    },
                    oConfig: function (error) {
                        console.log('今日风口接口报错：', error);
                        $('.jrfk').hide();
                        getYaoWenInfo(); //要闻三条
                    },
                });
            }
            function JRFKEvent() {
                //跳转今日风口模块
                $('.jrfk .more')
                    .off()
                    .on('click', function () {
                        //今日风口事件埋点
                        track.sensors.track('second_list_click', {
                            bottomtabbar_name: '探索',
                            toptabbar_name: '首页',
                            first_list_name: '今日风口',
                            second_list_type: '列表',
                            second_list_name: '今日风口',
                        });

                        // 首页栏位点击-今日风口-栏目
                        pageSensors.reportClick('mainPageColumnClick', {
                            column_type: '今日风口',
                            column_name: '今日风口-更多',
                            column_no: '',
                        });

                        var oSend = { secondtype: 0, url: '/hq/jrfk.html' };
                        T.fn.action10061(oSend);
                    });
                //跳转对应主题
                $('.jrfk .box-item')
                    .off()
                    .on('click', function () {
                        //今日风口列表事件埋点
                        var location = $(this).attr('data-location');
                        var index = $(this).attr('data-index');
                        track.sensors.track('second_list_click', {
                            bottomtabbar_name: '探索',
                            toptabbar_name: '首页',
                            first_list_name: '今日风口',
                            second_list_type: '列表位置',
                            second_list_name: location,
                        });

                        // 首页栏位点击-今日风口-栏目
                        pageSensors.reportClick('mainPageColumnClick', {
                            column_type: '今日风口',
                            column_name: $(this).find('.content-top').text(),
                            column_no: index,
                        });

                        var sId = $(this).find('.title').attr('data-id');
                        var obj = {
                            url: '/hq/zt_xq.html?id=' + sId + '',
                        };
                        var oSend = { url: obj.url };
                        TZT.fn.action10061(oSend);
                    });
            }
            // 主题详情
            function getZTXQ(id, dom1, dom2) {
                var oSendData = {
                    action: '50052',
                    channel_num: '1', //渠道识别，备注：可以在配置文件里面改，要和华福约定，暂时先用1
                    menu_id: '005',
                    ReqLinkType: '2',
                    nPage: 1,
                    maxcount: 10,
                    plate_id: id,
                };
                $.getData({
                    oSendData: oSendData,
                    isload: false,
                    fnSuccess: function (data) {
                        //console.log("主题详情：",data)
                        if (data && data.GRID0.length >= 1) {
                            var oData = data.GRID0[0].split('|');
                            var codeArr = [];
                            for (var i = 0; i < data.GRID0.length; i++) {
                                var oData1 = data.GRID0[i].split('|');
                                codeArr.push(oData1[data.STOCK_CODE]);
                                if (i == data.GRID0.length - 1) {
                                    getStock1(codeArr, dom2);
                                }
                            }

                            dom1.html(oData[data.PLATE_DESC]);
                        } else {
                            //暂无数据
                        }
                    },
                    oConfig: function (error) {
                        console.log('主题详情接口报错：', error);
                    },
                });
            }
            /*今日风口获取股票涨跌幅*/
            function getStock1(stockcode, oDom) {
                if (stockcode) {
                    var oSendData = {
                        Action: 60,
                        grid: stockcode.join(','),
                        NewMarketNo: 1,
                        ReqlinkType: 2,
                        maxCount: 100,
                        AccountIndex: 0,
                        StockIndex: 1,
                    };
                    $.getData({
                        oSendData: oSendData,
                        copyIsArray: false,
                        isload: false,
                        fnSuccess: function (data) {
                            //console.log("股票：",data,data.GRID0[1].split("|")[data.UPDOWNPINDEX]);return;
                            var _zdf = data.GRID0[1].split('|')[data.UPDOWNPINDEX],
                                zdClass = '';
                            if (Number(_zdf.replace('%', '')) > 0) {
                                //判断股票是涨幅还是跌幅
                                zdClass = 'zf';
                                _zdf = '+' + _zdf;
                            } else {
                                zdClass = 'df';
                            }
                            //console.log(oDom,oDom.parent());
                            oDom.parent().addClass(zdClass);
                            oDom.html(_zdf);
                            oDom.parent().find('.code').attr('date-id', data.GRID0[1].split('|')[data.STOCKCODEINDEX]);
                            var _name = data.GRID0[1].split('|')[data.STOCKNAMEINDEX];
                            if (_name.indexOf('.') > -1) {
                                _name = _name.split('.')[1];
                            }
                            oDom.parent().find('.code').html(_name);
                        },
                    });
                } else {
                    return null;
                }
            }

            /*处理格林尼治时间*/
            function setDateTime(fnTime) {
                var x = fnTime; // 取得时间"2017-07-08 13:00:00"
                if (!T.judge('ISIOS')) {
                    x = fnTime;
                } else {
                    //处理下，ios转换有问题
                    x = fnTime.replace(/-/g, '/');
                }
                var time = new Date(x);
                var timeNum = 8; //小时数
                time.setHours(time.getHours() + timeNum);
                return time;
            }
            Date.prototype.format = function (fmt) {
                var o = {
                    'M+': this.getMonth() + 1, //月份
                    'd+': this.getDate(), //日
                    'h+': this.getHours(), //小时
                    'm+': this.getMinutes(), //分
                    's+': this.getSeconds(), //秒
                    'q+': Math.floor((this.getMonth() + 3) / 3), //季度
                    S: this.getMilliseconds(), //毫秒
                };
                if (/(y+)/.test(fmt)) {
                    fmt = fmt.replace(RegExp.$1, (this.getFullYear() + '').substr(4 - RegExp.$1.length));
                }
                for (var k in o) {
                    if (new RegExp('(' + k + ')').test(fmt)) {
                        fmt = fmt.replace(
                            RegExp.$1,
                            RegExp.$1.length == 1 ? o[k] : ('00' + o[k]).substr(('' + o[k]).length)
                        );
                    }
                }
                return fmt;
            };
            /*今日关注获取股票涨跌幅*/
            function getStock2(stockcode) {
                if (stockcode) {
                    var oSendData = {
                        Action: 60,
                        grid: stockcode.join(','),
                        NewMarketNo: 1,
                        ReqlinkType: 0,
                        maxCount: 100,
                        AccountIndex: 0,
                        StockIndex: 1,
                    };
                    $.getData({
                        oSendData: oSendData,
                        copyIsArray: false,
                        isload: false,
                        fnSuccess: function (data) {
                            for (var i = 1; i < data.GRID0.length; i++) {
                                var oData = data.GRID0[i].split('|');
                                var _zdf = oData[data.UPDOWNPINDEX],
                                    zdClass = '';
                                if (Number(_zdf.replace('%', '')) > 0) {
                                    //判断股票是涨幅还是跌幅
                                    zdClass = 'zf';
                                    _zdf = '+' + _zdf;
                                } else if (Number(_zdf.replace('%', '')) < 0) {
                                    zdClass = 'df';
                                }
                                $('.jrgz .code').each(function () {
                                    if ($(this).attr('data-id') == oData[data.STOCKCODEINDEX]) {
                                        $(this).next().html(_zdf);
                                        $(this).parent().addClass(zdClass);
                                    }
                                });
                            }
                        },
                        oConfig: function (error) {
                            console.log(error);
                        },
                    });
                } else {
                    return null;
                }
            }

            /*要闻三条*/
            function getYaoWenInfo() {
                var oSendData = {
                    action: '31020',
                    param: JSON.stringify({
                        accessKey: 'e6ce431bd537718a',
                        infoOffset: oVal.infoOffset, //当前已遍历查询的资讯页数，默认为 0
                        page: oVal.ywPageNum - 1,
                    }),
                    ReqLinkType: '2',
                };
                $.getData({
                    oSendData: oSendData,
                    copyIsArray: false,
                    isload: false,
                    fnSuccess: function (data) {
                        // console.log("推荐-要闻",data,JSON.parse(data.BINDATA));
                        var sHtml = '',
                            sHtmlOther = '';
                        if (data.BINDATA) {
                            var _result = JSON.parse(data.BINDATA).data;
                            oVal.infoOffset = JSON.parse(data.BINDATA).infoOffset;
                            if (_result.length > 0) {
                                oVal.ywNextPage = JSON.parse(data.BINDATA).hasNext;
                                for (var i = 0; i < _result.length; i++) {
                                    var obj = {};
                                    obj.id = _result[i].itemId; //id
                                    obj.ctime = _result[i].time; //时间，日期
                                    obj.imgUrl = _result[i].imgUrl; //图片
                                    obj.source = _result[i].source; //来源
                                    obj.title = _result[i].title; //标题
                                    obj.copyright = _result[i].copyright; //有无版权
                                    obj.url = _result[i].url; //无版权时的三方地址

                                    if (i < 3) {
                                        if (obj.copyright && obj.copyright == '1') {
                                            sHtml += loadDOM_TT(obj);
                                        }
                                    } else {
                                        if (obj.copyright && obj.copyright == '1') {
                                            sHtmlOther += loadDOM_TT(obj);
                                        }
                                    }
                                }
                            }
                        }
                        $('.yaowen-list-three').html(sHtml);
                        $('.yaowen-list-other').html(sHtmlOther);
                        pageUrl();
                        getTGY(); //推广图
                    },
                    oConfig: function () {
                        getTGY(); //推广图
                    },
                });
            }
            function loadDOM_TT(data) {
                var readClass = '';
                /*if(readId.toString().indexOf(data.id) > -1){
                readClass='zx-read-name';
            }*/
                var newDate = dateStr(formatDate(data.ctime));
                //var newDate = formatDateHM(data.ctime);
                var sHtml =
                    '<li class="zx-list" data-copyright="' +
                    data.copyright +
                    '" data-url="' +
                    data.url +
                    '" data-id="' +
                    data.id +
                    '"  data-time="' +
                    formatDate(data.ctime) +
                    '"  data-title="' +
                    data.title +
                    '"  data-source="' +
                    data.source +
                    '">' +
                    /*+'<img  src="'+ data.imgUrl +'" onload=this.nextSibling.style.display="none"; class="img">'
                +'<img  src="./img/moren.png" class="none">'*/
                    '<p class="zx-name ' +
                    readClass +
                    '">' +
                    data.title +
                    '</p><p class="zx-foot">' +
                    '<span class="zx-date">' +
                    newDate +
                    '</span>' +
                    '<span class="zx-media" style="float: left;padding-right: 0.1rem;">' +
                    data.source +
                    '</span></p>' +
                    '</li>';
                return sHtml;
            }
            function formatDate(timestamp) {
                var date = new Date(timestamp * 1000); //时间戳为10位需*1000，时间戳为13位的话不需乘1000
                var Y = date.getFullYear(),
                    M = date.getMonth() + 1 < 10 ? date.getMonth() + 1 : date.getMonth() + 1,
                    D = date.getDate(),
                    h = date.getHours(),
                    m = date.getMinutes(),
                    s = date.getSeconds();
                M = M < 10 ? '0' + M : M;
                D = D < 10 ? '0' + D : D;
                h = h < 10 ? '0' + h : h;
                m = m < 10 ? '0' + m : m;
                s = s < 10 ? '0' + s : s;
                return Y + '-' + M + '-' + D + ' ' + h + ':' + m + ':' + s;
            }
            function formatDateHM(timestamp) {
                var date = new Date(timestamp * 1000); //时间戳为10位需*1000，时间戳为13位的话不需乘1000
                var Y = date.getFullYear(),
                    M = date.getMonth() + 1 < 10 ? date.getMonth() + 1 : date.getMonth() + 1,
                    D = date.getDate(),
                    h = date.getHours(),
                    m = date.getMinutes(),
                    s = date.getSeconds();
                M = M < 10 ? '0' + M : M;
                D = D < 10 ? '0' + D : D;
                h = h < 10 ? '0' + h : h;
                m = m < 10 ? '0' + m : m;
                s = s < 10 ? '0' + s : s;
                return h + ':' + m;
            }

            //旧版资讯推荐
            function getOldYaoWenInfo() {
                //上拉加载的回调
                var oSendData = {
                    action: '46118', //东财转开利，接口做调整
                    nPage: '1',
                    maxcount: '20',
                    menu_id: '20001' /*20024,20023,20025,20017*/,
                    ReqLinkType: '2',
                };
                $.getData({
                    oSendData: oSendData,
                    copyIsArray: false,
                    isload: false,
                    fnSuccess: function (data) {
                        var aGrid = data.GRID0;
                        var sHtml = '',
                            sHtmlOther = '';
                        if (aGrid) {
                            for (var i = 0; i < aGrid.length; i++) {
                                var _result = aGrid[i].split('|');
                                var obj = {};
                                obj.id = _result[data['IDINDEX']]; //id
                                obj.ctime = _result[data['DATESINDEX']]; //时间，日期
                                obj.imgUrl = _result[data['PICURLINDEX']]; //图片
                                obj.source = _result[data['MEDIAINDEX']]; //来源
                                obj.title = _result[data['INFOTITLEINDEX']]; //标题

                                if (i < 3) {
                                    sHtml += loadDOM_TT_Old(obj);
                                } else {
                                    sHtmlOther += loadDOM_TT_Old(obj);
                                }
                            }
                        }

                        if (aGrid.length >= 20) {
                            oVal.ywNextPage = true;
                        } else {
                            oVal.ywNextPage = false;
                        }

                        $('.yaowen-list-three').html(sHtml);
                        $('.yaowen-list-other').html(sHtmlOther);
                        pageUrlOld();
                    },
                    oConfig: function () {
                        pageUrlOld();
                    },
                });
            }
            function loadDOM_TT_Old(data) {
                var readClass = '';
                /*if(readId.toString().indexOf(data.id) > -1){
                readClass='zx-read-name';
            }*/
                var newDate = dateStr(data.ctime);
                var sHtml =
                    '<li class="zx-list" data-id="' +
                    data.id +
                    '">' +
                    /*+'<img  src="'+ data.imgUrl +'" onload=this.nextSibling.style.display="none"; class="img">'
                +'<img  src="./img/moren.png" class="none">'*/
                    '<p class="zx-name ' +
                    readClass +
                    '">' +
                    data.title +
                    '</p><p class="zx-foot">' +
                    '<span class="zx-date">' +
                    newDate +
                    '</span>' +
                    '<span class="zx-media" style="float: left;padding-right: 0.1rem;">' +
                    data.source +
                    '</span></p>' +
                    '</li>';
                return sHtml;
            }
            function pageUrlOld() {
                var action = 'read.txt';
                $('.zx-list')
                    .off()
                    .on('click', function () {
                        var imgsrc = encodeURIComponent($(this).find('img').attr('src'));
                        var sId = $(this).attr('data-id');
                        var obj = {
                            url: '/zx2/zx_zxxq.html?id=' + sId + '&&type=tuijian&&imgsrc=' + imgsrc,
                        };
                        pageSensors.reportClick('mainPageColumnClick', {
                            column_type: '要闻',
                            column_name: '要闻点击',
                            column_no: $(this).index(),
                        });

                        $(this).find('.zx-name').addClass('zx-read-name');
                        if (readId.toString().indexOf(sId) == -1) {
                            readId.push(sId);
                        }
                        T.saveFileMesg(readId, action, function (oData) {
                            T.readFileMesg(action, function (oData) {
                                var oSend = { url: obj.url };
                                oSend.secondtype = '98';
                                oSend.secondtext = 'tzt_zx.png';
                                oSend.secondjsfuncname = 'tztPageSecodeFun()';
                                oSend.TitleSkinType = 1;
                                TZT.fn.action10061(oSend);
                            });
                        });
                    });
            }

            function dateStr(date) {
                //console.log(date)
                var nowDate = new Date();
                var time = nowDate.getTime();
                var nowyear = nowDate.getFullYear();
                var year = date.substr(0, 4);
                var month = Number(date.substr(5, 2));
                var day = Number(date.substr(8, 2));
                var hour = Number(date.substr(11, 2));
                var minute = Number(date.substr(14, 2));
                var second = Number(date.substr(17, 2));
                var newDate = new Date(year, month - 1, day, hour, minute, second).getTime();
                time = parseInt((time - newDate) / 1000);
                var s;
                if (time < 60 * 5) {
                    //五分钟内
                    return '刚刚';
                } else if (time < 60 * 60 && time >= 60 * 5) {
                    //超过十分钟少于1小时
                    s = Math.floor(time / 60);
                    return s + '分钟前';
                } else if (time < 60 * 60 * 24 && time >= 60 * 60) {
                    //超过1小时少于24小时
                    s = Math.floor(time / 60 / 60);
                    return s + '小时前';
                } else if (time < 60 * 60 * 24 * 3 && time >= 60 * 60 * 24) {
                    //超过1天少于3天内
                    s = Math.floor(time / 60 / 60 / 24);
                    return s + '天前';
                } else {
                    //超过3天
                    if (year == nowyear) {
                        return date.substr(5, 5);
                    } else {
                        return date.split(' ')[0];
                    }
                }
            }
            function dateStrTG(date) {
                //console.log(date)
                var nowDate = new Date();
                var time = nowDate.getTime();
                var nowyear = nowDate.getFullYear();
                var year = date.substr(0, 4);
                var month = Number(date.substr(5, 2));
                var day = Number(date.substr(8, 2));
                var hour = Number(date.substr(11, 2));
                var minute = Number(date.substr(14, 2));
                var second = Number(date.substr(17, 2));
                var newDate = new Date(year, month - 1, day, hour, minute, second).getTime();
                time = parseInt((time - newDate) / 1000);
                var s;
                if (time < 60 * 5) {
                    //五分钟内
                    return '刚刚';
                } else if (time < 60 * 60 && time >= 60 * 5) {
                    //超过十分钟少于1小时
                    s = Math.floor(time / 60);
                    return s + '分钟前';
                } else if (time < 60 * 60 * 24 && time >= 60 * 60) {
                    //超过1小时少于24小时
                    s = Math.floor(time / 60 / 60);
                    return s + '小时前';
                } else if (time < 60 * 60 * 24 * 3 && time >= 60 * 60 * 24) {
                    //超过1天少于3天内
                    s = Math.floor(time / 60 / 60 / 24);
                    return s + '天前';
                } else {
                    //超过3天
                    return date;
                    /*if (year == nowyear) {
                    return date.substr(5,5);
                }else{
                    return date.split(" ")[0];
                }*/
                }
            }
            function pageUrl() {
                var action = 'read.txt';
                $('.zx-list')
                    .off()
                    .on('click', function () {
                        var sId = $(this).attr('data-id'),
                            time = $(this).attr('data-time'),
                            source = $(this).attr('data-source'),
                            jumpurl = $(this).attr('data-url'),
                            copyright = $(this).attr('data-copyright'),
                            title = $(this).attr('data-title');
                        var obj = {
                            url:
                                '/zx2/zx_zxxq.html?type=ths&id=' +
                                sId +
                                '&time=' +
                                encodeURIComponent(time) +
                                '&source=' +
                                encodeURIComponent(source),
                        };
                        var oSend = { url: obj.url };

                        pageSensors.reportClick('mainPageColumnClick', {
                            column_type: '要闻',
                            column_name: '要闻点击',
                            column_no: $(this).index(),
                        });

                        // $(this).find(".zx-name").addClass('zx-read-name');
                        if (readId.toString().indexOf(sId) == -1) {
                            readId.push(sId);
                        }
                        T.saveMapMesg({ THSPAGETITLE: title }, function () {});
                        T.saveFileMesg(readId, action, function (oData) {
                            T.readFileMesg(action, function (oData) {
                                if (copyright == '1') {
                                    TZT.fn.action10061(oSend);
                                } else {
                                    TZT.fn.action10061({ url: jumpurl });
                                }
                            });
                        });
                    });
            }

            //推广图
            function getTGY() {
                $.getData({
                    oSendData: {
                        action: '41500',
                        type: 'TGJDT',
                        ReqlinkType: '2',
                    },
                    isload: false,
                    fnSuccess: function (oData) {
                        // console.log(oData)
                        if (oData.GRID0 && oData.GRID0.length > 1) {
                            var data_grid = oData.GRID0;
                            data_grid.shift();
                            var sHtml = '';
                            for (var i = 0; i < 1; i++) {
                                var data = data_grid[i].split('|'),
                                    click_url = data[oData.IMAGE_CLICK_INDEX],
                                    img_title = data[oData.IMAGE_TITLE_INDEX],
                                    img_url = data[oData.IMAGE_URL_INDEX];
                                if (img_url) {
                                    sHtml +=
                                        '<img class="image" src="' +
                                        img_url +
                                        '" data-title="' +
                                        img_title +
                                        '" data-url="' +
                                        click_url +
                                        '" onerror="$(this).remove();">';
                                }
                            }

                            $('.extension-banner').html(sHtml).show();
                            TGYEvent();
                        } else {
                            $('.extension-banner').hide();
                        }
                        setHeight();
                    },
                    oConfig: function (error) {
                        $('.extension-banner').hide();
                    },
                });
            }
            function TGYEvent() {
                $('.extension-banner img')
                    .off()
                    .on('click', function () {
                        var url = $(this).attr('data-url');
                        var title = $(this).attr('data-title');
                        if (url) {
                            pageSensors.reportClick('bannerClick', {
                                banner_id: 0,
                                banner_name: title,
                                jump_url: url,
                            });
                            T.fn.changeURL(url);
                            //T.fn.action10061({url:url});
                        }
                    });
            }

            /*投顾两条*/
            var testIp = '';
            function getTGGD() {
                $.getData({
                    oSendData: {
                        action: '49245',
                        ReqlinkType: 2,
                        funcNo: '1106403', //1106403,1106416
                        dataType: 'json',
                        num_per_page: '2',
                        method: 'post',
                    },
                    isload: false,
                    fnSuccess: function (data) {
                        if (data) {
                            if (data.DATA) {
                                $('.tougu-group').show();
                                testIp = data.ERRORMESSAGE;
                                var oData = $.parseJSON($.parseJSON(data.DATA));
                                oData = oData[0].data;
                                // console.log(oData);
                                var itemHtml = '';
                                for (var i = 0; i < oData.length; i++) {
                                    var face_image_small = oVal.tgJumpId + oData[i].face_image_small,
                                        invest_id = oData[i].invest_id,
                                        introdution = oData[i].introdution,
                                        read_num = oData[i].read_num,
                                        title = oData[i].title,
                                        view_type = oData[i].view_type,
                                        invest_label = oData[i].invest_label, //1=金牌投顾，2=明星投顾，3=投资顾问
                                        create_time = oData[i].create_time,
                                        is_pay = oData[i].is_pay, //是否付费
                                        invest_name = oData[i].invest_name;
                                    create_time = dateStrTG(create_time);
                                    var className = '';
                                    if (invest_label == '1') {
                                        invest_label = '金牌投顾';
                                        className = 'tougu-jp';
                                    } else if (invest_label == '2') {
                                        invest_label = '明星投顾';
                                        className = 'tougu-mx';
                                    } else if (invest_label == '3') {
                                        invest_label = '投资顾问';
                                    } else {
                                        invest_label = '';
                                    }
                                    var payHtml = '';
                                    if (is_pay == '1') {
                                        payHtml = '<em>付费</em>';
                                    }
                                    itemHtml +=
                                        '<div class="tougu-list" data-id="' +
                                        invest_id +
                                        '">\n' +
                                        '                <div class="tougu-head">\n' +
                                        '                <span class="head-img">\n' +
                                        '                    <img src="' +
                                        face_image_small +
                                        '" alt="">\n' +
                                        '                </span>\n' +
                                        '                    <span class="head-name">' +
                                        invest_name +
                                        '</span>\n' +
                                        '                    <span class="head-desc ' +
                                        className +
                                        '"><em>' +
                                        invest_label +
                                        '</em></span>\n' +
                                        '                </div>\n' +
                                        '                <div class="tougu-title">\n' +
                                        '                    <span class="title-desc">' +
                                        title +
                                        payHtml +
                                        '</span>\n' +
                                        '                    <span class="title-icon"></span>\n' +
                                        '                </div>\n' +
                                        '                <div class="tougu-content">' +
                                        introdution +
                                        '</div>\n' +
                                        '                <div class="tougu-footer">\n' +
                                        '                    <span class="footer-read">' +
                                        read_num +
                                        '人正在观看</span>\n' +
                                        '                    <span class="footer-time">' +
                                        create_time +
                                        '</span>\n' +
                                        '                </div>\n' +
                                        '            </div>';
                                }

                                $('.tougu-group').html(itemHtml);
                                TGGDEvent();
                            } else {
                                $('.tougu-group').hide();
                            }
                        }
                    },
                    oConfig: function (error) {
                        $('.tougu-group').hide();
                    },
                });
            }
            function TGGDEvent() {
                //跳转观点详情
                $('.tggd .tougu-list')
                    .off()
                    .on('click', function () {
                        //牛人观点事件埋点
                        var location = $(this).attr('data-location');
                        track.sensors.track('second_list_click', {
                            bottomtabbar_name: '探索',
                            toptabbar_name: '首页',
                            first_list_name: '牛人观点',
                            second_list_type: '列表位置',
                            second_list_name: location,
                        });

                        // 首页栏位点击-投顾观点
                        pageSensors.reportClick('mainPageColumnClick', {
                            column_type: '要闻',
                            column_name: '要闻点击',
                            column_no: $(this).index(),
                        });

                        var id = $(this).data('id');
                        //var url = testIp + '/m/ytg/views/loadPage.html?toPagecode=point/detail&view_id=' + id + '&source_id=hzzz';
                        var url = testIp + '/m/app/#/?toPagecode=viewDetail&view_id=' + id + '&source_id=hzzz';
                        tgFunc(url);
                    });
            }
            function tgFunc(url) {
                T.readLocalMesg(['jyloginflag', 'logintype=1', 'MOBILECODE', 'usercode'], function (oLocal) {
                    var MOBILECODE = oLocal.MOBILECODE;
                    var USERCODE = oLocal.USERCODE;
                    if (MOBILECODE == '' || !MOBILECODE || MOBILECODE == 'null') {
                        //console.log(url);
                        T.fn.action10061({ url: url, tzthiddentitle: '1', tztadjustnever: '1' });
                    } else {
                        if (oLocal.JYLOGINFLAG <= 1) {
                            //未登录
                            var oSend = {
                                action: '5',
                                needToken: '0',
                            };
                            $.getData({
                                oSendData: oSend,
                                isToken: false,
                                fnSuccess: function (oTime) {
                                    var serverTime = oTime.TIME;
                                    var oSend = {
                                        action: '46200',
                                        ReqlinkType: 2,
                                    };
                                    $.getData({
                                        oSendData: oSend,
                                        fnSuccess: function (oData) {
                                            var PUBLICK_KEY = oData.TG,
                                                MD5_KEY = oData.HSSTRING;
                                            var str = JSON.stringify({
                                                mobile: MOBILECODE,
                                                from: 'sidi',
                                                time: serverTime,
                                            });
                                            //处理rsa和md5key
                                            var senddata = encryptRsaTg(PUBLICK_KEY, MD5_KEY, str);
                                            var oUrl = url + '&data=' + encodeURIComponent(senddata.data);
                                            //console.log(oUrl);
                                            //console.log(senddata.data);
                                            if (T.appversion.andriod()) {
                                                T.fn.action10061({
                                                    url:
                                                        url +
                                                        '&data=' +
                                                        encodeURIComponent(encodeURIComponent(senddata.data)),
                                                    tzthiddentitle: '1',
                                                    tztadjustnever: '1',
                                                });
                                            } else {
                                                T.fn.action10061({
                                                    url: oUrl,
                                                    tzthiddentitle: '1',
                                                    tztadjustnever: '1',
                                                });
                                            }
                                        },
                                    });
                                },
                            });
                        } else {
                            var oSend = {
                                action: '5',
                                needToken: '0',
                            };
                            $.getData({
                                oSendData: oSend,
                                isToken: false,
                                fnSuccess: function (oTime) {
                                    var serverTime = oTime.TIME;
                                    /*if(oLocal.JYLOGINFLAG <=1){ //未登录
                                    T.fn.action10061({url:url,'tzthiddentitle':'1','tztadjustnever':'1'});
                                }else{*/
                                    var oSendData = {
                                        action: 6771,
                                        ReqlinkType: '1',
                                    };
                                    $.getData({
                                        oSendData: oSendData,
                                        fnSuccess: function (reg) {
                                            var SERVTICKET_ID = reg.SERVTICKET_ID;
                                            var oSend = {
                                                action: '46200',
                                                ReqlinkType: 2,
                                            };
                                            $.getData({
                                                oSendData: oSend,
                                                fnSuccess: function (oData) {
                                                    var PUBLICK_KEY = oData.TG,
                                                        MD5_KEY = oData.HSSTRING;
                                                    var str = JSON.stringify({
                                                        token: SERVTICKET_ID,
                                                        mobile: MOBILECODE,
                                                        client_id: USERCODE,
                                                        from: 'sidi',
                                                        time: serverTime,
                                                    });
                                                    //处理rsa和md5key
                                                    var senddata = encryptRsaTg(PUBLICK_KEY, MD5_KEY, str);
                                                    var oUrl = url + '&data=' + senddata.data;
                                                    if (T.appversion.andriod()) {
                                                        T.fn.action10061({
                                                            url:
                                                                url +
                                                                '&data=' +
                                                                encodeURIComponent(encodeURIComponent(senddata.data)),
                                                            tzthiddentitle: '1',
                                                            tztadjustnever: '1',
                                                        });
                                                    } else {
                                                        T.fn.action10061({
                                                            url: oUrl,
                                                            tzthiddentitle: '1',
                                                            tztadjustnever: '1',
                                                        });
                                                    }
                                                },
                                            });
                                        },
                                    });
                                    /*}*/
                                },
                            });
                        }
                    }
                });
            }

            /*视频课程一条*/
            function getSPKC() {
                $.getData({
                    oSendData: {
                        action: '49245',
                        ReqlinkType: 2,
                        funcNo: '1106391',
                        dataType: 'json',
                        method: 'post',
                    },
                    isload: false,
                    fnSuccess: function (data) {
                        if (data) {
                            if (data.DATA) {
                                $('.video-list').show();
                                testIp = data.ERRORMESSAGE;
                                var oData = $.parseJSON($.parseJSON(data.DATA));
                                oData = oData[0].data;
                                // console.log("视频课程：",oData);
                                var ln = data.length,
                                    itemHtml = '';
                                for (var i = 0; i < 1; i++) {
                                    var curriculum_image = oVal.tgJumpId + oData[i].curriculum_image,
                                        curriculum_id = oData[i].curriculum_id;
                                    itemHtml +=
                                        '<img data-id="' + curriculum_id + '" src="' + curriculum_image + '" alt="">';
                                }

                                $('.video-list').html(itemHtml);

                                $('.video-list img')
                                    .off()
                                    .on('click', function () {
                                        if (oVal.configData) {
                                            //课程详情字段TGCLASSDETAILLINK
                                            if (oVal.configData.TGCLASSDETAILLINK) {
                                                var oUrl = oVal.configData.TGCLASSDETAILLINK.replace(
                                                    '{id}',
                                                    $(this).attr('data-id')
                                                );
                                                // 首页栏位点击-牛人观点
                                                pageSensors.reportClick('mainPageColumnClick', {
                                                    column_type: '要闻',
                                                    column_name: '视频点击',
                                                    column_no: 0,
                                                });

                                                T.fn.action10061({
                                                    url: oUrl,
                                                    tzthiddentitle: '1',
                                                    tztadjustnever: '1',
                                                });
                                            }
                                        }
                                    });
                            } else {
                                $('.video-list').hide();
                            }
                        }
                    },
                    oConfig: function (error) {
                        $('.video-list').hide();
                    },
                });
            }

            /*要闻其他数据*/
            function getYaoWenOtherInfo() {
                var oSendData = {
                    action: '31020',
                    param: JSON.stringify({
                        accessKey: 'e6ce431bd537718a',
                        infoOffset: oVal.infoOffset, //当前已遍历查询的资讯页数，默认为 0
                        page: oVal.ywPageNum - 1,
                    }),
                    ReqLinkType: '2',
                };
                $.getData({
                    oSendData: oSendData,
                    copyIsArray: false,
                    isload: false,
                    fnSuccess: function (data) {
                        // console.log(data,JSON.parse(data.BINDATA));
                        var sHtml = '';
                        if (data.BINDATA) {
                            var _result = JSON.parse(data.BINDATA).data;
                            oVal.infoOffset = JSON.parse(data.BINDATA).infoOffset;
                            if (_result.length > 0) {
                                oVal.ywNextPage = JSON.parse(data.BINDATA).hasNext;
                                for (var i = 0; i < _result.length; i++) {
                                    var obj = {};
                                    obj.id = _result[i].itemId; //id
                                    obj.ctime = _result[i].time; //时间，日期
                                    obj.imgUrl = _result[i].imgUrl; //图片
                                    obj.source = _result[i].source; //来源
                                    obj.title = _result[i].title; //标题
                                    obj.copyright = _result[i].copyright; //有无版权
                                    obj.url = _result[i].url; //无版权时的三方地址
                                    if (obj.copyright && obj.copyright == '1') {
                                        sHtml += loadDOM_TT(obj);
                                    }
                                }
                                $('.yaowen-list-other').append(sHtml);
                                pageUrl();
                                oVal.loadYWFlag = true;
                                setHeight();
                            }
                        }
                    },
                    oConfig: function () {},
                });
            }

            //旧版资讯推荐
            function getOldYaoWenOtherInfo() {
                var oSendData = {
                    action: '46118', //东财转开利，接口做调整
                    nPage: oVal.ywPageNum,
                    maxcount: '20',
                    menu_id: '20001' /*20024,20023,20025,20017*/,
                    ReqLinkType: '2',
                };
                $.getData({
                    oSendData: oSendData,
                    copyIsArray: false,
                    isload: false,
                    fnSuccess: function (data) {
                        var aGrid = data.GRID0;
                        var sHtml = '';
                        if (aGrid) {
                            for (var i = 0; i < aGrid.length; i++) {
                                var _result = aGrid[i].split('|');
                                var obj = {};
                                obj.id = _result[data['IDINDEX']]; //id
                                obj.ctime = _result[data['DATESINDEX']]; //时间，日期
                                obj.imgUrl = _result[data['PICURLINDEX']]; //图片
                                obj.source = _result[data['MEDIAINDEX']]; //来源
                                obj.title = _result[data['INFOTITLEINDEX']]; //标题

                                sHtml += loadDOM_TT_Old(obj);
                            }
                        }

                        if (aGrid.length >= 20) {
                            oVal.ywNextPage = true;
                        } else {
                            oVal.ywNextPage = false;
                        }

                        $('.yaowen-list-other').append(sHtml);
                        pageUrlOld();
                        oVal.loadYWFlag = true;
                    },
                    oConfig: function () {},
                });
            }

            /**
             * 获取配置文件信息
             * */
            function getConfigInfo(callback) {
                $.getData({
                    oSendData: {
                        action: '46200',
                        ReqlinkType: 2,
                    },
                    isload: false,
                    fnSuccess: function (oData) {
                        oVal.configData = oData;
                        callback();
                    },
                    oConfig: function (error) {
                        console.log(error);
                        callback();
                    },
                });
            }

            window.loadMoreData = function () {
                if(oVal.loadYWFlag && oVal.ywNextPage){
                    // console.log("加载数据");
                    oVal.loadYWFlag = false;
                    oVal.ywPageNum++;
                    getYaoWenOtherInfo()
                }
            };

        </script>
    </body>
</html>
